package demo1;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 何华树
 * Date: 2024-09-04
 * Time: 13:07
 */
public class Dog extends Animal implements Irunning,Iswimming{
    public Dog(String name, int age) {
        super(name, age);
    }

    @Override
    public void eat() {
        System.out.println(this.name+" 正在吃狗粮.");
    }

    @Override
    public void run() {
        System.out.println(this.name+"在吐着舌头欢快的跑步。");
    }

    @Override
    public void swim() {
        System.out.println(this.name+"在水里用狗刨式游泳。");
    }
}
